<?php

namespace AppBundle\Controller;

use Symfony\Bundle\FrameworkBundle\Controller\Controller;
use Sensio\Bundle\FrameworkExtraBundle\Configuration\Route;

class ArticleController extends Controller
{
    /**
     * annotation 直接生效
     * @Route(
     *     "/articles/{_locale}/{year}/{slug}.{_format}",
     *     defaults={"_format": "json"},
     *     requirements={
     *         "_locale": "en|fr",
     *         "_format": "html|rss",
     *         "year": "\d+"
     *     },
     *     name="article_show_list"
     * )
     */
    public function showAction($_locale, $year, $slug)
    {
        echo $_locale;
        echo "\n";
        echo $year;
        echo "\n";
        echo $slug;
        echo "\n";
        return 'ccccccccccccccccccc';
        exit;
    }
}